import xdc.runtime.Startup;

import amaret.freestyle.mcu.lm3s811.stellarisware.Driver_gpio;
import amaret.freestyle.mcu.lm3s811.stellarisware.Driver_i2c;
import amaret.freestyle.mcu.lm3s811.stellarisware.Driver_sysctl;

@ModuleStartup
module Display {

    Void drawText( String str, Int line = 0, Int col = 0 );

}

implementation {

    native {
        #include "drivers/osram96x16x1.c"
    }

    function Module_startup( state )
    {
        ^OSRAM96x16x1Init(false);
        return Startup.DONE;
    }

    function drawText( str, line, col )
    {
        ^OSRAM96x16x1StringDraw(str, col * 8, line * 6);
    }

}
